//
//  CycleBaseTableView.m
//  CycleBaseControl
//
//  Created by ddy on 2018/8/14.
//  Copyright © 2018年 cycle. All rights reserved.
//

#import "CycleBaseTableView.h"

@implementation CycleBaseTableView

-(void)awakeFromNib{
    [super awakeFromNib];
    [self cycle_initTableViewSource];
}
-(instancetype)initWithFrame:(CGRect)frame style:(UITableViewStyle)style{
    if (self = [super initWithFrame:frame style:style]) {
        [self cycle_initTableViewSource];
    }
    return self;
}
/**
 *  初始化基本信息
 */
- (void)cycle_initTableViewSource{
    
    if (@available(iOS 11.0, *)) {
        self.estimatedRowHeight             = 0;
        self.estimatedSectionFooterHeight   = 0;
        self.estimatedSectionHeaderHeight   = 0;
        ///contentInsetAdjustmentBehavior属性也是用来取代automaticallyAdjustsScrollViewInsets属性的，推荐使用这种方式。
        if ([self respondsToSelector:@selector(setContentInsetAdjustmentBehavior:)]) {
            self.contentInsetAdjustmentBehavior = UIScrollViewContentInsetAdjustmentNever;
        }
        
    }
    
}

@end
